
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package mytools;

import com.opensymphony.xwork2.ActionSupport;
import java.util.List;

/**

 *

 * @author xiaoxiao

 */
public class alluser extends ActionSupport {

    private int pagenumber;
    private int pagesize;
    private int totalpage;
    private List<user> alluser;
    private int num;

    public alluser() {
    }

    public String execute() throws Exception {

        userDAO qd = new userDAO();
        setNum(qd.getuserAmount());
        setAlluser(qd.getuserlist(getPagenumber(), getPagesize()));
        return SUCCESS;

    }

    /**
     * @return the pagenumber
     */
    public int getPagenumber() {
        return pagenumber;
    }

    /**
     * @param pagenumber the pagenumber to set
     */
    public void setPagenumber(int pagenumber) {
        this.pagenumber = pagenumber;
    }

    /**
     * @return the pagesize
     */
    public int getPagesize() {
        return pagesize;
    }

    /**
     * @param pagesize the pagesize to set
     */
    public void setPagesize(int pagesize) {
        this.pagesize = pagesize;
    }

    /**
     * @return the totalpage
     */
    public int getTotalpage() {
        return totalpage;
    }

    /**
     * @param totalpage the totalpage to set
     */
    public void setTotalpage(int totalpage) {
        this.totalpage = totalpage;
    }

    /**
     * @return the alluser
     */
    public List<user> getAlluser() {
        return alluser;
    }

    /**
     * @param alluser the alluser to set
     */
    public void setAlluser(List<user> alluser) {
        this.alluser = alluser;
    }

    /**
     * @return the num
     */
    public int getNum() {
        return num;
    }

    /**
     * @param num the num to set
     */
    public void setNum(int num) {
        this.num = num;
    }
}
